<?php
if( !defined( '_VALID_MOS' ) && !defined( '_JEXEC' ) ) die( 'Direct Access to '.basename(__FILE__).' is not allowed.' );

// Load the virtuemart main parse code
if( file_exists(dirname(__FILE__).'/../../components/com_virtuemart/virtuemart_parser.php' )) {
    require_once( dirname(__FILE__).'/../../components/com_virtuemart/virtuemart_parser.php' );
} else {
    require_once( dirname(__FILE__).'/../components/com_virtuemart/virtuemart_parser.php' );
}

global $mm_action_url, $sess;
?>
<script language="javascript">
function SearchPos() {
    var obj = new Object();
        
    obj.search = function() {        
        $('search_pos').submit();
    }
    
    return obj;
}

var _SearchPos_ = new SearchPos();
</script>
<form id="search_pos" name="search_pos" method="post" action="<?php echo $sess->purl( $mm_action_url."index.php?page=shop.search_pos&option=com_virtuemart&Itemid=12" ); ?>">
    <table align="center" border="0" cellpadding="0" cellspacing="0" style="width: 750px;">
        <tbody>
            <tr>
                <td style="width: 320px;">
                    <input maxlength="100" id="txtLocation" name="txtLocation" size="37" type="text" placeholder="Address, City, State, or Zip" value="<?php echo JRequest::getString("txtLocation", ""); ?>" /></td>
                <td style="width: 259px;">
                    <input maxlength="50" id="txtHungry" name="txtHungry" size="37" type="text" placeholder="e.g., Italian, Greek, Mexican" value="<?php echo JRequest::getString("txtHungry", ""); ?>" /></td>
                <td style="width: 141px;">
                    <a href="javascript:void(0);" onclick="_SearchPos_.search();">
                        <img alt="" src="images/stories/leteat.png" style="width: 127px; height: 44px; float: right;" />
                    </a>
                </td>
            </tr>
            <tr>
                <td style="width: 320px;">
                <span style="color: black;font-size: 12px;">Where are you? or </span><span style="color: red;font-size: 12px;">Current Location</span></td>
                <td style="width: 259px;">
                <span style="color: red;font-size: 12px;">What are you hungry for?</span></td>
                <td style="width: 141px;">
                    &nbsp;</td>
            </tr>
            <tr>
                <td colspan="3">
                <div style="width: 100%;text-align: center;margin-top: 10px;margin-bottom: 5px;">
                Menutise is a free service. Prices are as they appear on the restaurants’ menus.
                </div>
                </td>
            </tr>
        </tbody>
    </table>
</form>